package com.zjitc.config;

import com.zaxxer.hikari.HikariDataSource;
import javax.sql.DataSource;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * Create by IntelliJ IDEA
 *
 * @author: jsonor
 * @date-Time: 2018/3/8 15:31
 * @description:
 */
@Component
@PropertySource("classpath:db.properties")
public class DataSourceProperties
{

  @Value("${jdbc.driver}")
  private String driverClass;

  @Value("${jdbc.password}")
  private String password;

  @Value("${jdbc.username}")
  private String username;

  @Value("${jdbc.url}")
  private String jdbcUrl;

  public DataSourceProperties()
  {
  }

  public String getDriverClass()
  {
    return driverClass;
  }

  public void setDriverClass(String driverClass)
  {
    this.driverClass = driverClass;
  }

  public String getPassword()
  {
    return password;
  }

  public void setPassword(String password)
  {
    this.password = password;
  }

  public String getUsername()
  {
    return username;
  }

  public void setUsername(String username)
  {
    this.username = username;
  }

  public String getJdbcUrl()
  {
    return jdbcUrl;
  }

  public void setJdbcUrl(String jdbcUrl)
  {
    this.jdbcUrl = jdbcUrl;
  }
}
